import {
  BASE_URL
} from '@/settings'
import request from '@/utils/request'


//app端查询当前员工必填字段信息
export function getFieldQuery(companyId, empInfoId) {
  return request({
    url: `${BASE_URL}/hr/api/v1/companyNecessaryFields/listAllForApp?companyId=${companyId}&empInfoId=${empInfoId}`,
    method: 'get'
  })
}
//app端修改公司员工信息
export function putAndValueListVO(data) {
  return request({
    url: `${BASE_URL}/hr/api/v1/companyNecessaryFields/updateForApp`,
    method: 'put',
    data
  })
}
//app端查询当前员工某个模块的字段信息
export function getFieldQuery2(companyId, empInfoId, moduleCode, id) {
  return request({
    url: `${BASE_URL}/hr/api/v1/companyNecessaryFields/listForAppModule?companyId=${companyId}&empInfoId=${empInfoId}&moduleCode=${moduleCode}&id=${id}`,
    method: 'get'
  })
}
//app端修改公司员工某个模块的信息
export function putAndValueListVO2(data) {
  return request({
    url: `${BASE_URL}/hr/api/v1/companyNecessaryFields/updateAppForModule`,
    method: 'put',
    data
  })
}
//app删除单个员工家庭成员，彻底删除
export function DELETEempFamilies(id) {
  return request({
    url: `${BASE_URL}/hr/api/v1/empFamilies/${id}`,
    method: 'delete'
  })
}
// 删除单个员工紧急联系人，彻底删除
export function DELETEempContactsUrgents(id) {
  return request({
    url: `${BASE_URL}/hr/api/v1/empContacts/deleteEmpContacts/${id}`,
    method: 'delete'
  })
}
// 删除单个求职用户教育经历，彻底删除
export function DELETEuserEempEducations(id) {
  return request({
    url: `${BASE_URL}/hr/api/v1/empEducations/${id}`,
    method: 'delete'
  })
}
//删除工作经历
export function DELETEempWorks(id) {
  return request({
    url: `${BASE_URL}/hr/api/v1/empWorks/${id}`,
    method: 'delete'
  })
}
//app删除单个公司员工培训记录所需信息，彻底删除
export function DELETEempTrainRequires(id) {
  return request({
    url: `${BASE_URL}/hr/api/v1/empTrains/${id}`,
    method: 'delete'
    
  })
}